﻿using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Text;
using System.Windows.Forms;

namespace UI.ParentForm
{
    public partial class BaseTMain : BaseMain
    {
        bool IsChildLoadCompleteTree = false;
        public BaseTMain()
        {
            InitializeComponent();
        }

        public BaseTMain(string modulecode, string action)
            : base(modulecode, action)
        {
            InitializeComponent();

            LoadTree();
        }

        protected override void BindGrid()
        {
            base.BindGrid();
        }

        protected virtual void LoadTree()
        {

        }

        protected override void OnLoad(EventArgs e)
        {
            base.OnLoad(e);

            _SetFontSize();
        }

        protected override void AutoSize()
        {
            this.dgvMain.Width = this.ClientSize.Width - this.treeMain.ClientSize.Width;
        }

        void _SetFontSize()
        {
            this.treeMain.Font = UI.Lib.Global.AllFont;
        }
    }
}
